// 对axios进行二次封装
import axios from 'axios'
// const instance = axios.create({}) // 创建实例
axios.defaults.baseURL = 'http://geek.itheima.net/'
axios.defaults.timeout = 8000

export default ({ url, method, params, data, headers }) =>
  axios({
    url,
    data,
    params,
    method,
    headers
  })
